-module(mochiweb_hello2).
-export([h/2]).

-include_lib("ewgi/include/ewgi.hrl").

h(Env, StartResp) ->
    StartResp(?OK, []),
    Qs = ewgi_api:qs(Env),
    ParsedQs = ewgi_api:parse_qs(Qs),
    Name = ewgi_api:get_value("name", ParsedQs, "World"),
    Resp = ["<html>
<head><title>Hello!</title></head>
<body>
<h1>Hello ", Name, "!</h1>
</body>"],
    Resp.

